import PropTypes from 'prop-types';
import React, { memo } from 'react';
import { LongforItemWrapper } from './style';

const LongforItem = memo((props) => {
  const { itemData } = props;
  return (
    <LongforItemWrapper>
      <div className="cover">
        <div className="info">
          <img className="cover_img" src={itemData.picture_url} alt="" />
          <div className="bg_cover"></div>
          <div className="cover_info">
            <div className="cover_city">{itemData.city}</div>
            <div className="cover_price">均价 {itemData.price}</div>
          </div>
        </div>
      </div>
    </LongforItemWrapper>
  );
});

LongforItem.propTypes = {
  itemData: PropTypes.object,
};

export default LongforItem;
